package com.fise.mwtvc

import android.content.BroadcastReceiver
import android.content.Context
import android.content.Intent
import android.util.Log

class BootReceiver : BroadcastReceiver() {

    override fun onReceive(context: Context, intent: Intent?) {
        Log.i("BootReceiver", "BootReceiver onReceive $intent")
//        if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.O) {
//            context.startForegroundService(Intent(context, DaemonService::class.java))
//        } else {
//            context.startService(Intent(context, MyService::class.java))
//        }
        context.startService(Intent(context, MyService::class.java))
    }
}